package com.anti.modular.bus.houselease.service;

import com.anti.jdbc.support.page.PageParam;
import com.anti.jdbc.support.page.PageResult;
import com.anti.modular.bus.housebill.entity.HouseBill;
import com.anti.modular.bus.houselease.entity.HouseLease;
import com.anti.modular.bus.houselease.param.HouseLeaseParam;
import com.anti.modular.bus.houselease.param.HouseLeaseParam2;
import com.anti.modular.bus.houselease.param.HouseLeaseTzParam;
import com.anti.modular.bus.houselease.result.HouseLeaseResult;
import com.anti.modular.bus.houselease.result.LeaseFurnitureShResult;
import com.anti.modular.bus.houselease.result.TjSysRes;
import com.anti.modular.bus.houselease.result.excel.LeaseExcel;
import com.anti.modular.bus.roomexpenses.entity.LeaseExpenses;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * 房间租约service接口
 *
 * @author anti
 * @date 2021-05-06 09:30:21
 */
public interface HouseLeaseService{

    /**
    * 根据主键查询实体
    */
    HouseLease getById(HouseLeaseParam houseLeaseParam);

    HouseLease getByLeaseId(Long id);

    /**
     * 查询房间租约
     *
     * @author anti
     * @date 2021-05-06 09:30:21
     */
    PageResult page(PageParam pageParam,HouseLeaseParam houseLeaseParam);

    /**
     * 房间租约列表
     *
     * @author anti
     * @date 2021-05-06 09:30:21
     */
    List<HouseLease> list(HouseLeaseParam houseLeaseParam);


    List<LeaseFurnitureShResult> getLeaseFurnitureList(Long id);

    /**
     * 添加房间租约
     *
     * @author anti
     * @date 2021-05-06 09:30:21
     */
    void add(HouseLeaseParam houseLeaseParam);

    /**
     * 删除房间租约
     *
     * @author anti
     * @date 2021-05-06 09:30:21
     */
    void delete(HouseLeaseParam houseLeaseParam);

    /**
     * 编辑房间租约
     *
     * @author anti
     * @date 2021-05-06 09:30:21
     */
    void edit(HouseLeaseParam houseLeaseParam);
    void editZk(HouseLeaseParam houseLeaseParam);
    void editFy(HouseLeaseParam2 houseLeaseParam);
    void editJs(HouseLeaseParam2 houseLeaseParam);

    void editTzQs(HouseLeaseParam houseLeaseParam);

    void editTuiZu(HouseLeaseTzParam houseLeaseParam);
    void editXuzu(HouseLeaseTzParam houseLeaseParam);

    /**
     * 查看房间租约
     *
     * @author anti
     * @date 2021-05-06 09:30:21
     */
     HouseLease detail(HouseLeaseParam houseLeaseParam);

    TjSysRes getTjSys(HouseLeaseParam houseLeaseParam);

    List<LeaseExcel> getExportData(HouseLeaseParam houseLeaseParam);

    HouseLeaseResult getIsLeaseMsgForPrint(Long id);

    Long addBillBysDNo(String busType,HouseBill houseBill,HouseLease houseLease,Date date,Long sysLoginUserId,
                       long pkMain,int billEndType,Integer billEndTqData,
                       Integer billEndGdmonthData,Integer billEndGddayData);
    void createRentedDay(int billEndType, Integer billEndTqData, Integer billEndGdmonthData, Integer billEndGddayData, HouseBill houseBill);
    void addZjDetailForOne(int amount, BigDecimal relRent,int calculateStyle, HouseBill houseBill, HouseLease houseLease, Date date, Long sysLoginUserId,
                           Long billPk);

    void addExpensesDetailForAllOne(int qsNum,Long preBillId,HouseLease houseLease, String rentDay,
                                    Date date, Long sysLoginUserId, List<LeaseExpenses> expensesList, Long billPk);

    void addExpensesDetailForAllOneByType(int qsNum, Long preBillId,HouseLease houseLease,String rentDay,
                                          Date date, Long sysLoginUserId, List<LeaseExpenses> expensesList, Long billPk,int sdType);
}
